//    Copyright (C) Kherty.  All rights reserved.
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Text;
using System.Windows;
using System.Windows.Input;

namespace OpenLS.UI
{
    public class GalleryElement : DependencyObject
    {


        static readonly ICommand _expand = new RoutedCommand("Expand", typeof(GalleryElement));
        public static ICommand Expand { get { return _expand; } }



        // Using a DependencyProperty as the backing store for IsExpanded.  This enables animation, styling, binding, etc...



        internal static object GetLastSelected(DependencyObject obj)
        {
            return (object)obj.GetValue(LastSelectedProperty);
        }

        internal static void SetLastSelected(DependencyObject obj, object value)
        {
            obj.SetValue(LastSelectedProperty, value);
        }
        // Using a DependencyProperty as the backing store for LastSelected.  This enables animation, styling, binding, etc...
        internal static readonly DependencyProperty LastSelectedProperty =
            DependencyProperty.RegisterAttached("LastSelected", typeof(object), typeof(GalleryElement), new UIPropertyMetadata(null));




        public static int GetMinColumns(DependencyObject obj)
        {
            return (int)obj.GetValue(MinColumnsProperty);
        }

        public static void SetMinColumns(DependencyObject obj, int value)
        {
            obj.SetValue(MinColumnsProperty, value);
        }

        // Using a DependencyProperty as the backing store for MinColumns.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty MinColumnsProperty =
            DependencyProperty.RegisterAttached("MinColumns", typeof(int), typeof(GalleryElement),  new FrameworkPropertyMetadata(2, FrameworkPropertyMetadataOptions.Inherits));



        public static int GetMaxColumns(DependencyObject obj)
        {
            return (int)obj.GetValue(MaxColumnsProperty);
        }

        public static void SetMaxColumns(DependencyObject obj, int value)
        {
            obj.SetValue(MaxColumnsProperty, value);
        }

        // Using a DependencyProperty as the backing store for Columns.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty MaxColumnsProperty =
            DependencyProperty.RegisterAttached("MaxColumns", typeof(int), typeof(GalleryElement), new FrameworkPropertyMetadata(2, FrameworkPropertyMetadataOptions.Inherits));



        public static double GetExpandedWidth(DependencyObject obj)
        {
            return (double)obj.GetValue(ExpandedWidthProperty);
        }

        public static void SetExpandedWidth(DependencyObject obj, double value)
        {
            obj.SetValue(ExpandedWidthProperty, value);
        }

        // Using a DependencyProperty as the backing store for ExpandedWidth.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty ExpandedWidthProperty =
            DependencyProperty.RegisterAttached("ExpandedWidth", typeof(double), typeof(GalleryElement), new UIPropertyMetadata(500.0));


        public static bool GetIsOpen(DependencyObject obj)
        {
            return (bool)obj.GetValue(IsOpenProperty);
        }

        public static void SetIsOpen(DependencyObject obj, bool value)
        {
            obj.SetValue(IsOpenProperty, value);
        }

        // Using a DependencyProperty as the backing store for IsOpen.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty IsOpenProperty =
            DependencyProperty.RegisterAttached("IsOpen", typeof(bool), typeof(GalleryElement), new FrameworkPropertyMetadata(false));



    }
}
